package com.woniu.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.woniu.commons.exception.YogaException;
import com.woniu.model.dto.LoadListByPersonalCLassDto;
import com.woniu.model.dto.PersonalClassDto;
import com.woniu.model.model.YPersonalClass;
import com.woniu.model.param.CoachByPagePersonalParam;
import com.woniu.model.param.CoachByPersonalParam;
import com.woniu.model.param.CoachPagePersonalClassParam;
import com.woniu.model.param.PersonalClassAddParam;
import com.woniu.model.param.PersonalClassUpdateStateParam;
import io.swagger.models.auth.In;

import java.util.List;

/**
 * <p>
 * 服务类
 * </p>
 *
 * @author 吴彦祖
 * @since 2024年05月23日
 */
public interface YPersonalClassService extends IService<YPersonalClass> {


    /**
     * 新增私课
     *
     * @param param：coachId：教练；price：价格；minute：分钟数（课程时长）；classTypeId：课程类型id
     * @return
     * @throws YogaException
     */
    public void addPersonalClass(PersonalClassAddParam param) throws YogaException;


    /**
     * 修改私课状态为可预约
     *
     * @param
     * @return
     * @throws YogaException
     */
    public void updatePersonalClassState(Integer personalClassId) throws YogaException;

    /**
     * 传私教课ID查询一个私教课回去
     *
     * @param id：私教课id
     * @return
     * @throws YogaException
     */
    public YPersonalClass byIdPersonal(Integer id) throws YogaException;


    /**
     * 删除私课
     *
     * @param ：leagueClassId：私课id
     * @return
     * @throws YogaException
     */
    public void deletePersonalClassState(Integer personalClassId) throws YogaException;


    /**
     * 查询私课集合
     *
     * @return
     */
    public List loadListPersonalClass() throws YogaException;


    /**
     * 通过教练Id查该教练的私课
     *
     * @param coachId：教练id
     * @return
     */
    public List CoachByIdPersonalClass(Integer coachId) throws YogaException;


    /**
     * 通过token查该教练的私课
     *
     * @param param
     * @return
     */
    public Page<PersonalClassDto> CoachByPageIdPersonalClass(CoachByPagePersonalParam param)throws YogaException;

    /**
     * 通过场馆的token查私课
     * @param param
     * @return
     */
    public Page<PersonalClassDto> VenueByPageIdPersonalClass(CoachByPersonalParam param)throws YogaException;

    Page<PersonalClassDto> CoachPagePersonalClass(CoachPagePersonalClassParam param);


    /**
     * 查询私课集合,带教练名字查
     *
     * @return
     */
    LoadListByPersonalCLassDto loadListByPersonalClass(String coachName);
}
